<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>Title</title>
    <meta name="renderer" content="webkit">
    <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
    <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1">
    <link rel="stylesheet" href="../plugins/layui/css/layui.css" media="all" />
    <link rel="stylesheet" href="../plugins/layui/css/myPage.css">
</head>
<body  style=" overflow-x:hidden;">

    <!--<div class="layui-tab">-->
        <!--<ul class="layui-tab-title">-->
            <!--<li class="layui-this">车辆资料</li>-->
            <!--<li>运营资料</li>-->
            <!--<li>图片信息</li>-->
        <!--</ul>-->
        <form class=" layui-form">
            <div class=" layui-show">
                <div class="layui-container ">
                    <div class="layui-row ">
                        <div class="layui-col-md12">
                            <fieldset class="layui-elem-field  " style="margin-top: 20px;">
                                <legend>车辆基本信息</legend>


                                <div class="layui-form-item">
                                    <label class="layui-form-label"><span style="color: red;">*</span>车牌号</label>
                                    <div class="layui-input-inline" style="width: 150px;">
                                        <input   type="text" name="cph"   required lay-verify="required" placeholder="请输入"  class="layui-input"  >
                                        <input   type="hidden" name="sfcz"   value="1"   >
                                        <input   type="hidden" name="clid"    id="clid"  >
                                        <input   type="hidden" name="sffp"    id="sffp"  value="未分配" >
                                    </div>


                                    <div class="layui-input-inline" style="width: 60px;">
                                    <select name="zhuorgua"  >

                                    <option value="挂">挂</option>
                                    <option value="主">主</option>
                                    </select>
                                    </div>

                                    <label class="layui-form-label" > 主(挂)车车号</label>
                                    <div class="layui-input-inline" style="width: 150px;">
                                        <input type="text" name="zgcch"   required  placeholder="请输入" autocomplete="off" class="layui-input">
                                    </div>

                                    <label class="layui-form-label"><span style="color: red;">*</span>所属部门</label>

                                    <div class="layui-input-inline" style="width: 150px;">
                                        <input type="hidden" name="bumenid">
                                        <select name="bumenid" required lay-verify="required" id="ssbm" lay-search >
                                            <option value=""></option>

                                        </select>
                                    </div>
                                    <label class="layui-form-label" style="width: 110px;"><span style="color: red;">*</span>是否外叫车</label>
                                    <div class="layui-input-inline" style="width: 60px;" >
                                        <select name="sfwjc" required lay-verify="required">
                                            <option value="否">否</option>
                                            <option value="是">是</option>
                                        </select>
                                    </div>

                                </div>


                                <div class="layui-form-item">

                                    <label class="layui-form-label" > 档案编号</label>
                                    <div class="layui-input-inline" style="width: 150px;">
                                        <input type="text" name="dabh"     placeholder="请输入" autocomplete="off" class="layui-input">
                                    </div>

                                    <label class="layui-form-label" > 车辆类型</label>
                                    <div class="layui-input-inline" style="width: 150px;">
                                        <input type="text" name="cllx"     placeholder="请输入" autocomplete="off" class="layui-input">
                                    </div>

                                    <label class="layui-form-label" > 车辆品牌</label>
                                    <div class="layui-input-inline" style="width: 150px;">
                                        <input type="text" name="clpp"     placeholder="请输入" autocomplete="off" class="layui-input">
                                    </div>
                                    <label class="layui-form-label" > 车辆型号</label>
                                    <div class="layui-input-inline" style="width: 150px;">
                                        <input type="text" name="clxh"    placeholder="请输入" autocomplete="off" class="layui-input">
                                    </div>

                                </div>

                                <div class="layui-form-item">

                                    <label class="layui-form-label" >车架号</label>
                                    <div class="layui-input-inline" style="width: 150px;">
                                        <input type="text" name="cjh"   lay-verify="" placeholder="请输入" autocomplete="off" class="layui-input">
                                    </div>

                                    <label class="layui-form-label" >发动机号</label>
                                    <div class="layui-input-inline" style="width: 150px;">
                                        <input type="text" name="fdjh"   lay-verify="" placeholder="请输入" autocomplete="off" class="layui-input">
                                    </div>
                                    <label class="layui-form-label" >登记日期</label>
                                    <div class="layui-input-inline" style="width: 150px;">
                                        <input id="djrq" type="text" name="djrq"   lay-verify="" placeholder="请输入" autocomplete="off" class="layui-input">
                                    </div>

                                    <label class="layui-form-label" >速通卡</label>
                                    <div class="layui-input-inline" style="width: 150px;">
                                        <input type="text" name="stk"   lay-verify="" placeholder="请输入" autocomplete="off" class="layui-input">
                                    </div>

                                </div>



                            </fieldset>


                        </div>
                    </div>
                    <div class="layui-row">
                        <div class="layui-col-md12">
                            <fieldset class="layui-elem-field  " style="margin-top: 20px;">
                                <legend>车辆详细信息</legend>


                            <div class="layui-form-item">
                                <label class="layui-form-label">进口/国产</label>
                                <div class="layui-input-inline" style="width: 150px;">
                                    <select name="gcorjk">
                                        <option value=""></option>
                                        <option value="进口">进口</option>
                                        <option value="国产">国产</option>
                                    </select>
                                </div>

                                <div class="layui-inline" >
                                    <label class="layui-form-label"  >车身颜色</label>
                                    <div class="layui-input-inline"  style="width: 150px;" >
                                        <input type="text" lay-verify="" name="csys" autocomplete="off" class="layui-input">
                                    </div>
                                </div>




                                <div class="layui-inline" >
                                    <label class="layui-form-label">发动机型号</label>
                                    <div class="layui-input-inline"  style="width: 150px;" >
                                        <input type="text" lay-verify="" name="fdjxh" autocomplete="off" class="layui-input">
                                    </div>
                                </div>

                                <div class="layui-inline">
                                    <label class="layui-form-label" style="width: 60px">核定载客</label>
                                    <div class="layui-input-inline" style="width: 150px;">
                                        <input type="text" name="hdzk" autocomplete="off" class="layui-input">
                                    </div>
                                </div>





                            </div>
                            <div class="layui-form-item">

                                <div class="layui-inline">
                                    <label class="layui-form-label">准牵引总质量</label>
                                    <div class="layui-input-inline" style="width: 150px;">
                                        <input type="text" name="zqyzzl" autocomplete="off" class="layui-input">
                                    </div>
                                </div>

                                <div class="layui-inline">
                                    <label class="layui-form-label" style="width: 79px;">驾驶室载客</label>
                                    <div class="layui-input-inline" style="width: 150px;">
                                        <input type="text" name="jsszk" autocomplete="off" class="layui-input">
                                    </div>
                                </div>

                                <div class="layui-inline" >
                                    <label class="layui-form-label"  style="width: 90px">整备质量</label>
                                    <div class="layui-input-inline"  style="width: 150px;" >
                                        <input type="text" lay-verify="" name="zbzl" autocomplete="off" class="layui-input">
                                    </div>
                                </div>

                                <div class="layui-inline">
                                    <label class="layui-form-label" style="width: auto">排量/功率</label>
                                    <div class="layui-input-inline" style="width: 150px;">
                                        <input type="text" name="plorgl" autocomplete="off" class="layui-input">
                                    </div>
                                </div>


                            </div>
                            <div class="layui-form-item">
                                <div class="layui-inline" >
                                    <label class="layui-form-label"  >制造厂商</label>
                                    <div class="layui-input-inline"  style="width: 150px;" >
                                        <input type="text" lay-verify="" name="zzcs" autocomplete="off" class="layui-input">
                                    </div>
                                </div>


                                <label class="layui-form-label">转向形式</label>
                                <div class="layui-input-inline" style="width: 150px;">
                                    <select name="zxxs">
                                        <option value=""></option>
                                        <option value="方向盘">方向盘</option>
                                        <option value="无">无</option>
                                    </select>
                                </div>
                                <div class="layui-inline">
                                    <label class="layui-form-label">押运员</label>
                                    <div class="layui-input-inline" style="width: 150px;">
                                        <input type="text" name="yyy" autocomplete="off" class="layui-input">
                                    </div>
                                </div>
                                <div class="layui-inline" >
                                    <label class="layui-form-label" style="width: 60px" >发证机关</label>
                                    <div class="layui-input-inline"  style="width: 150px;" >
                                        <input type="text" lay-verify="" name="fzjg" autocomplete="off" class="layui-input">
                                    </div>
                                </div>
                            </div>



                            <div class="layui-form-item">
                                <div class="layui-inline" >
                                    <label class="layui-form-label" style="width: 96px">等级证书编号</label>
                                    <div class="layui-input-inline"  style="width: 150px;" >
                                        <input type="text" lay-verify="" name="djzsbh" autocomplete="off" class="layui-input">
                                    </div>
                                </div>
                                <div class="layui-inline">
                                    <label class="layui-form-label" style="width: 90px">轮距</label>
                                    <div class="layui-input-inline" style="width: 150px;">
                                        <input type="text" name="lunju" autocomplete="off" class="layui-input">
                                    </div>
                                </div>
                                <label class="layui-form-label" style="width: 90px">轮胎数量</label>
                                <div class="layui-input-inline" style="width: 150px;">
                                    <select name="ltsl">
                                        <option value=""></option>
                                        <option value="4*2">4*2</option>
                                        <option value="6*4">6*4</option>
                                        <option value="6*2">6*2</option>
                                    </select>
                                </div>
                                <div class="layui-inline">
                                    <label class="layui-form-label" style="width: 60px">轮胎规格</label>
                                    <div class="layui-input-inline" style="width: 150px;">
                                        <input type="text" name="ltgg" autocomplete="off" class="layui-input">
                                    </div>
                                </div>
                            </div>

                            <div class="layui-form-item">

                                <div class="layui-inline" >
                                    <label class="layui-form-label" style="width: 90px">轴数</label>
                                    <div class="layui-input-inline"  style="width: 150px;" >
                                        <input type="text" lay-verify="" name="zhoushu" autocomplete="off" class="layui-input">
                                    </div>
                                </div>

                                <div class="layui-inline" >
                                    <label class="layui-form-label"  style="width: 90px">钢板弹簧片数</label>
                                    <div class="layui-input-inline"  style="width: 150px;" >
                                        <input type="text" lay-verify="" name="gbthps" autocomplete="off" class="layui-input">
                                    </div>
                                </div>
                                <div class="layui-inline" >
                                    <label class="layui-form-label" style="width: 82px">轴距</label>
                                    <div class="layui-input-inline"  style="width: 150px;" >
                                        <input type="text" lay-verify="" name="zhouju" autocomplete="off" class="layui-input" id="zhouju">
                                    </div>
                                </div>
                                <div class="layui-inline" >
                                    <label class="layui-form-label" style="width: 60px">随车电话</label>
                                    <div class="layui-input-inline"  style="width: 150px;" >
                                        <input type="text" lay-verify="" name="scdh" autocomplete="off" class="layui-input" id="scdh">
                                    </div>
                                </div>

                            </div>
                            <div class="layui-form-item">

                                <div class="layui-inline" >
                                    <label class="layui-form-label">外廓尺寸(mm)</label>
                                    <div class="layui-input-inline"  style="width: 25px">
                                        <label class="layui-form-label" style="width: 10px">长</label>
                                        <label class="layui-form-label" style="width: 10px">宽</label>
                                        <label class="layui-form-label" style="width: 10px">高</label>
                                    </div>
                                    <div class="layui-input-inline"  style="width: 150px;" >
                                        <input type="text" lay-verify="" name="wlccc" autocomplete="off"   class="layui-input">
                                        <input type="text" lay-verify="" name="wlcck" autocomplete="off"   class="layui-input">
                                        <input type="text" lay-verify="" name="wlccg" autocomplete="off"   class="layui-input">
                                    </div>
                                </div>
                                <div class="layui-inline" >
                                    <label class="layui-form-label">货厢内部尺寸(mm)</label>
                                    <div class="layui-input-inline"  style="width: 25px">
                                        <label class="layui-form-label" style="width: 10px">长</label>
                                        <label class="layui-form-label" style="width: 10px">宽</label>
                                        <label class="layui-form-label" style="width: 10px">高</label>
                                    </div>
                                    <div class="layui-input-inline"  style="width: 150px;" >
                                        <input type="text" lay-verify="" name="hxnbccc" autocomplete="off"    class="layui-input">
                                        <input type="text" lay-verify="" name="hxnbcck" autocomplete="off"   class="layui-input">
                                        <input type="text" lay-verify="" name="hxnbccg" autocomplete="off"   class="layui-input">
                                    </div>
                                </div>

                                <div class="layui-inline" >
                                    <label class="layui-form-label" style="width: 80px">容积(m^3)</label>
                                    <div class="layui-input-inline"  style="width: 150px;" >
                                        <input type="text" lay-verify="" name="hxnbccrj" autocomplete="off" class="layui-input">
                                    </div>
                                </div>

                            </div>
                            </fieldset>
                        </div>
                    </div>
                    <div class="layui-row">
                        <div class="layui-col-md12">
                            <fieldset class="layui-elem-field  " style="margin-top: 20px;">
                                <legend>营运信息</legend>

                                <div class="layui-form-item">


                                    <label class="layui-form-label">营运证号</label>
                                    <div class="layui-input-inline" style="width: 150px;">
                                        <input type="text" name="yyzh" class="layui-input" >
                                    </div>

                                    <label class="layui-form-label">业主名称</label>
                                    <div class="layui-input-inline" style="width: 150px;">
                                        <input type="text" name="yzmc" class="layui-input" >
                                    </div>

                                    <label class="layui-form-label">营运吨位</label>
                                    <div class="layui-input-inline" style="width: 150px;">
                                        <input type="text" name="yydw" class="layui-input" >
                                    </div>

                                </div>
                                <div class="layui-form-item">

                                    <label class="layui-form-label">车辆出厂日期</label>
                                    <div class="layui-input-inline" style="width: 150px;">
                                        <input type="text" name="clccrq" class="layui-input" id="clccrq">
                                    </div>


                                    <label class="layui-form-label"   >营运范围</label>
                                    <div class="layui-input-inline" style="width: 150px;">
                                        <input type="text"   name="yyfw" autocomplete="off" class="layui-input">
                                    </div>
                                    <label class="layui-form-label"   >核发机关</label>
                                    <div class="layui-input-inline" style="width: 150px;">
                                        <input type="text" lay-verify="" name="hfjg" autocomplete="off" class="layui-input">
                                    </div>

                                    <div class="layui-inline">
                                        <label class="layui-form-label">核发日期</label>
                                        <div class="layui-input-inline" style="width: 150px;">
                                            <input type="text" name="hfrq" class="layui-input" id="hfrq">
                                        </div>
                                    </div>

                                </div>

                                <div class="layui-form-item">
                                    <label class="layui-form-label">运输类型</label>
                                    <div class="layui-input-inline" style="width: 150px;">
                                        <input type="text" name="yslx" class="layui-input" >
                                    </div>
                                    <div class="layui-inline" >
                                        <label class="layui-form-label"  >车载手机</label>
                                        <div class="layui-input-inline"  style="width: 150px;" >
                                            <input type="text" lay-verify="" name="czsj" autocomplete="off" class="layui-input">
                                        </div>
                                    </div>
                                    <div class="layui-inline">
                                        <label class="layui-form-label" style="width: 80px">总质量</label>
                                        <div class="layui-input-inline" style="width: 150px;">
                                            <input type="text" name="zzl" autocomplete="off" class="layui-input">
                                        </div>
                                    </div>
                                    <div class="layui-inline">
                                        <label class="layui-form-label" style="width: auto" >核定载质量</label>
                                        <div class="layui-input-inline" style="width: 150px;">
                                            <input type="text" name="hdzzl" autocomplete="off" class="layui-input">
                                        </div>
                                    </div>

                                </div>

                            <div class="layui-form-item">
                                <div class="layui-inline">
                                    <label class="layui-form-label" style="width: 100px">营运证有效期</label>
                                    <div class="layui-input-inline" style="width: 150px;">
                                        <input type="text" name="yyzyxq" class="layui-input" id="yyzyxq">
                                    </div>
                                </div>
                                <div class="layui-inline" >
                                    <label class="layui-form-label" style="width: 85px" >行驶证有效期</label>
                                    <div class="layui-input-inline"  style="width: 150px;" >
                                        <input type="text" lay-verify="" name="xszyxq"   class="layui-input" id="xszyxq">
                                    </div>
                                </div>
                                <div class="layui-inline" >
                                    <label class="layui-form-label" style="width: auto" >百公里油耗</label>
                                    <div class="layui-input-inline"  style="width: 150px;" >
                                        <input type="text" lay-verify="" name="bglyh"   class="layui-input" id="bglyh">
                                    </div>
                                </div>
                            </div>

                            </fieldset>

                        </div>
                    </div>
                    <div class="layui-row">
                        <div class="layui-col-md12">
                            <fieldset class="layui-elem-field  " style="margin-top: 20px;">
                                <legend>保险信息</legend>
                            <fieldset class="layui-elem-field layui-field-title " style="margin-top: 20px;">
                                <legend>机动车交通事故责任险</legend>
                            </fieldset>
                            <div class="layui-form-item">

                                <div class="layui-inline" >
                                    <label class="layui-form-label">保额(万元)</label>
                                    <div class="layui-input-inline" style="width: 150px;">
                                        <input type="text" name="jdcjtsgzrxbe" autocomplete="off" class="layui-input" id="jdcjtsgzrxbe">
                                    </div>
                                </div>
                                <div class="layui-inline" >
                                    <label class="layui-form-label" >有效期</label>
                                    <div class="layui-input-inline"  style="width: 150px;" >
                                        <input type="text"   name="jdcjtsgzrxyxq"   class="layui-input" id="jdcjtsgzrxyxq">
                                    </div>
                                </div>

                            </div>

                            <fieldset class="layui-elem-field layui-field-title " style="margin-top: 20px;">
                                <legend>第三者责任险</legend>
                            </fieldset>
                            <div class="layui-form-item">
                                <div class="layui-inline">
                                    <label class="layui-form-label">保额(万元)</label>
                                    <div class="layui-input-inline" style="width: 150px;">
                                        <input type="text" name="dszzrxbe" autocomplete="off" class="layui-input" id="dszzrxbe">
                                    </div>
                                </div>
                                <div class="layui-inline" >
                                    <label class="layui-form-label"  >有效期</label>
                                    <div class="layui-input-inline"  style="width: 150px;" >
                                        <input type="text" lay-verify="" name="dszzrxyxq" autocomplete="off" class="layui-input" id="dszzrxyxq">
                                    </div>
                                </div>

                            </div>

                            <fieldset class="layui-elem-field layui-field-title " style="margin-top: 20px;">
                                <legend>物流责任险</legend>
                            </fieldset>
                            <div class="layui-form-item">
                                <div class="layui-inline">
                                    <label class="layui-form-label">保额(万元)</label>
                                    <div class="layui-input-inline" style="width: 150px;">
                                        <input type="text" name="wlzrxbe" autocomplete="off" class="layui-input" id="wlzrxbe">
                                    </div>
                                </div>
                                <div class="layui-inline" >
                                    <label class="layui-form-label"  >有效期</label>
                                    <div class="layui-input-inline"  style="width: 150px;" >
                                        <input type="text" lay-verify="" name="wlzrxyxq" autocomplete="off" class="layui-input" id="wlzrxyxq">
                                    </div>
                                </div>

                            </div>

                            </fieldset>


                <div class="layui-row">
                    <div class="layui-col-md12">

                        <fieldset class="layui-elem-field " style="margin-top: 20px;">
                            <legend>车辆图片信息</legend>


                                <div class="layui-row" style="margin: 50px" >
                                    <div class="layui-col-md6">
                                        <div class="layui-inline">

                                            <label class="layui-form-label" style="width: 100px">营运证复印件</label>

                                                <input type="hidden" name="yyzfyj" autocomplete="off" class="layui-input" id="yyzfyj">

                                        </div>
                                        <div class="layui-input-inline"  >
                                            <button type="button" class="layui-btn layui-btn-normal  "   id="yyzfyjBtn">上传文件</button>
                                            <button type="button" class="layui-btn layui-btn-normal  "   id="lookyyzfyjBtn" style="display: none">查看文件</button>
                                        </div>
                                        <div class="layui-input-inline"  >
                                            <button type="button" class="layui-btn layui-btn-normal  " style="display: none"  id="delyyzfyjBtn">删除文件</button>
                                        </div>
                                    </div>
                                    <div class="layui-col-md6">
                                        <div class="layui-inline">
                                            <label class="layui-form-label" >行驶证复印件</label>

                                                <input type="hidden" name="xszfyj" autocomplete="off" class="layui-input" id="xszfyj">

                                        </div>
                                        <div class="layui-input-inline"  >
                                            <button type="button" class="layui-btn layui-btn-normal  "   id="xszfyjBtn">上传文件</button>
                                            <button type="button" class="layui-btn layui-btn-normal  "   id="lookxszfyjBtn" style="display: none">查看文件</button>
                                        </div>
                                        <div class="layui-input-inline"  >
                                            <button type="button" class="layui-btn layui-btn-normal  "  style="display: none" id="delxszfyjBtn">删除文件</button>
                                        </div>
                                    </div>
                                </div>
                                <div class="layui-row" style="margin: 50px" >
                                    <div class="layui-col-md6">
                                        <div class="layui-inline">
                                            <label class="layui-form-label" style="width: 100px">登记证书复印件</label>
                                                <input type="hidden" name="djzsfyj" autocomplete="off" class="layui-input" id="djzsfyj">
                                        </div>
                                        <div class="layui-input-inline"  >
                                            <button type="button" class="layui-btn layui-btn-normal  "   id="djzsfyjBtn">上传文件</button>
                                            <button type="button" class="layui-btn layui-btn-normal  "   id="lookdjzsfyjBtn" style="display: none">查看文件</button>
                                        </div>
                                        <div class="layui-input-inline"  >
                                            <button type="button" class="layui-btn layui-btn-normal  "  style="display: none" id="deldjzsfyjBtn">删除文件</button>
                                        </div>
                                    </div>
                                    <div class="layui-col-md6">
                                        <div class="layui-inline">
                                            <label class="layui-form-label">车辆图片</label>


                                                <input type="hidden" name="cltp" autocomplete="off" class="layui-input" id="cltp">

                                        </div>
                                        <div class="layui-input-inline"  >
                                            <button type="button" class="layui-btn layui-btn-normal "   id="cltpBtn">上传文件</button>
                                            <button type="button" class="layui-btn layui-btn-normal  "   id="lookcltpBtn" style="display: none">查看文件</button>
                                        </div>
                                        <div class="layui-input-inline"  >
                                            <button type="button" class="layui-btn layui-btn-normal  "  style="display: none" id="delcltpBtn">删除文件</button>
                                        </div>
                                    </div>
                                </div>




                        </fieldset>
                    </div>
                    </div>
                 </div>

            </div>
                </div>
            </div>
            <button class="layui-btn layui-btn-normal"  lay-submit  lay-filter="newCar" style="width: 10%; position: absolute;left: 35%"  >立即提交</button>
            <button type="reset" class="layui-btn layui-btn-normal" style="width: 10%; position: absolute;left: 55%" >重置</button>

        </form>
    <!--</div>-->
    <script src="../plugins/layui/layui.js"></script>
    <script src="../js/config.js"></script>
    <script src="../js/tools.js"></script>
<script>
    layui.use(['table','form','element','laydate','upload'],function () {
        var table = layui.table;
        var form = layui.form;
        var element = layui.element;
        var laydate = layui.laydate;
        var upload = layui.upload;
        var $ = layui.$;
        $("#clid").val(uuid());
        //小数补全

        $("#jdcjtsgzrxbe,#dszzrxbe,#wlzrxbe,#zhouju").on("blur",function(){
            if($(this).val()==""){
                return
            }else {
                return  $(this).val(parseFloat($(this).val()).toFixed(2));
            }
        });
        //渲染select
        $.ajax({
            url: contextPath+"/oilcardlist",
            type: "GET",
            contentType:"application/json;charset=utf-8",
            dataType:"json",
            success: function(res) {
                $("#searchContentSelect").append("<option value=''>请选择</option>");
                for(var i in res.list){
                    var option = "<option value='"+ res.list[i].ykh+ "'>"+res.list[i].ykh+"</option>";
                    $("#ykh").append(option);
                };
                form.render('select');
            }
        });
        //渲染驾驶员select
        $.ajax({
            url: contextPath+"/driverlist",
            type: "GET",
            contentType:"application/json;charset=utf-8",
            dataType:"json",
            success: function(res) {
                $("#searchContentSelect").append("<option value=''>请选择</option>");
                for(var i in res.list){
                    var option = "<option value='"+ res.list[i].jsyxm+ "'>"+res.list[i].jsyxm+"</option>";
                    $("#jsy").append(option);
                };
                form.render('select');
            }
        });
//渲染驾驶员select
        $.ajax({
            url: contextPath+"/deptlist",
            type: "GET",
            contentType:"application/json;charset=utf-8",
            dataType:"json",
            success: function(res) {
                $("#searchContentSelect").append("<option value=''>请选择</option>");
                for(var i in res.list){
                    var option = "<option value='"+ res.list[i].bumenid+ "'>"+res.list[i].name+"</option>";
                    $("#ssbm").append(option);
                };
                form.render('select');
            }
        });
//执行一个laydate实例
        laydate.render({
            elem: '#djrq' //指定元素
            ,theme:'#0099FF'
            ,format:'yyyy-MM-dd'
        });
        laydate.render({
            elem: '#clccrq' //指定元素
            ,theme:'#0099FF'
            ,format:'yyyy-MM-dd'
        });
        laydate.render({
            elem: '#hfrq' //指定元素
            ,theme:'#0099FF'
            ,format:'yyyy-MM-dd'
        });

        laydate.render({
            elem: '#xszyxq' //指定元素
            ,theme:'#0099FF'
            ,format:'yyyy-MM-dd'
        });

        laydate.render({
            elem: '#yyzyxq' //指定元素
            ,theme:'#0099FF'
            ,format:'yyyy-MM-dd'
        });
        laydate.render({
            elem: '#jdcjtsgzrxyxq' //指定元素
            ,theme:'#0099FF'
            ,format:'yyyy-MM-dd'
        });
        laydate.render({
            elem: '#dszzrxyxq' //指定元素
            ,theme:'#0099FF'
            ,format:'yyyy-MM-dd'
        });
        laydate.render({
            elem: '#wlzrxyxq' //指定元素
            ,theme:'#0099FF'
            ,format:'yyyy-MM-dd'
        });

        uploadOneFile(upload,$,layer,"carinfo",$("#clid").val(),"xszfyj");
        uploadOneFile(upload,$,layer,"carinfo",$("#clid").val(),"yyzfyj");
        uploadOneFile(upload,$,layer,"carinfo",$("#clid").val(),"djzsfyj");
        uploadOneFile(upload,$,layer,"carinfo",$("#clid").val(),"cltp");

        var delFileArr = new Array();

        delFile($,layer,"yyzfyj",delFileArr);
        delFile($,layer,"djzsfyj",delFileArr);
        delFile($,layer,"cltp",delFileArr);
        delFile($,layer,"xszfyj",delFileArr);

        lookFile($,layer,"xszfyj");
        lookFile($,layer,"yyzfyj");
        lookFile($,layer,"djzsfyj");
        lookFile($,layer,"cltp");

        form.on('submit(newCar)', function(data){

            $("input").css("border","");
            $("input").css("border","");
            for(var fileindex in delFileArr){
                $.ajax({
                    url: contextPath+"/files/"+delFileArr[fileindex],
                    type: "DELETE",
                    contentType:"application/json;charset=utf-8",
                    dataType:"json",
                    success: function(res) {

                    }

                });
            }

            $.ajax({
                url: contextPath+"/car",
                type: "POST",
                contentType:"application/json;charset=utf-8",
                data: JSON.stringify(data.field) ,
                dataType:"json",
                success: function(res) {
                    newSuccess($,layer,res);
                }
            });
            return false; //阻止表单跳转。如果需要表单跳转，去掉这段即可。
        });
    });

</script>
</body>
</html>